﻿<!--#include file="utf-8.asp"-->
<!--#include file="conn.asp"-->
<%
dim rs,sql,id 
id=request("id")
title=request.form("title")
etitle=request.form("etitle")
ProductNo=request.form("ProductNo")
body=request.form("body")
ebody=request.form("ebody")
ssfl=request.form("ssfl")
img =request.form("img") 
description2=request.form("description2")
edescription2=request.form("edescription2")
keyword=request.form("keyword")
ekeyword=request.form("ekeyword") 

if title=""  then 
response.Write("<script language=javascript>alert('案例中文名称不能为空!');history.go(-1)</script>") 
response.end 
end if
if etitle=""  then 
response.Write("<script language=javascript>alert('案例英文名称不能为空!');history.go(-1)</script>") 
response.end 
end if
if body="" then 
response.Write("<script language=javascript>alert('案例中文内容不能为空!');history.go(-1)</script>") 
response.end 
end if
if ebody="" then 
response.Write("<script language=javascript>alert('案例英文内容不能为空!');history.go(-1)</script>") 
response.end 
end if

sql="select * from cases where id="&id 
set rs=server.CreateObject("adodb.recordset")
rs.open sql,conn,1,3
rs("title")=title
rs("etitle")=etitle
rs("ProductNo")=ProductNo
rs("body")=body
rs("ebody")=ebody
rs("ssfl")=ssfl
rs("img")=img
rs("description2")=description2
rs("edescription2")=edescription2
rs("keyword")=keyword
rs("ekeyword")=ekeyword
rs.update
rs.close
set rs=nothing
conn.close
set conn = nothing
response.write "<script>alert('案例修改成功！');window.location.href='admin_cases.asp';</script>" 
%> 
